* sysdep.c [GNU_LINUX]: Fix fd and memory leaks and similar issues.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 19 Jul 2013 05:36:50 +0000 (22:36 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 19 Jul 2013 05:36:50 +0000 (22:36 -0700)
commit2e786e0280a1f9df7a501cfc87dc99229d7bb7a3
treedf447d94d756d7040636a1ecc405be71fe5345f2
parentbc29716effcaf12941c73d2a2675c16b2867fcc4
* sysdep.c [GNU_LINUX]: Fix fd and memory leaks and similar issues.

(procfs_ttyname): Don't use uninitialized storage if emacs_fopen
or fscanf fails.
(system_process_attributes): Prefer plain char to unsigned char
when either will do.  Clean up properly if interrupted or if
memory allocations fail.  Don't assume sscanf succeeds.  Remove
no-longer-needed workaround to stop GCC from whining.  Read
command-line once, instead of multiple times.  Check read status a
bit more carefully.
src/ChangeLog
src/sysdep.c